<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "https://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<html xmlns="http://www.w3.org/1999/xhtml">
<head>
<meta http-equiv="Content-Type" content="text/xhtml;charset=UTF-8"/>
<meta http-equiv="X-UA-Compatible" content="IE=9"/>
<meta name="generator" content="Doxygen 1.8.16"/>
<meta name="viewport" content="width=device-width, initial-scale=1"/>
<title>LibTools: H:/project/LibTools/src/ipc/internal/IpcServer.cpp 源文件</title>
<link href="tabs.css" rel="stylesheet" type="text/css"/>
<script type="text/javascript" src="jquery.js"></script>
<script type="text/javascript" src="dynsections.js"></script>
<link href="doxygen.css" rel="stylesheet" type="text/css" />
</head>
<body>
<div id="top"><!-- do not remove this div, it is closed by doxygen! -->
<div id="titlearea">
<table cellspacing="0" cellpadding="0">
 <tbody>
 <tr style="height: 56px;">
  <td id="projectalign" style="padding-left: 0.5em;">
   <div id="projectname">LibTools
   </div>
  </td>
 </tr>
 </tbody>
</table>
</div>
<!-- end header part -->
<!-- 制作者 Doxygen 1.8.16 -->
<script type="text/javascript" src="menudata.js"></script>
<script type="text/javascript" src="menu.js"></script>
<script type="text/javascript">
/* @license magnet:?xt=urn:btih:cf05388f2679ee054f2beb29a391d25f4e673ac3&amp;dn=gpl-2.0.txt GPL-v2 */
$(function() {
  initMenu('',false,false,'search.php','搜索');
});
/* @license-end */</script>
<div id="main-nav"></div>
<div id="nav-path" class="navpath">
  <ul>
<li class="navelem"><a class="el" href="dir_68267d1309a1af8e8297ef4c3efbcdba.html">src</a></li><li class="navelem"><a class="el" href="dir_b94456e2763cc4ff61641ee1fd517631.html">ipc</a></li><li class="navelem"><a class="el" href="dir_08f7e595e04b6b21bd129111ec77a9cc.html">internal</a></li>  </ul>
</div>
</div><!-- top -->
<div class="header">
  <div class="headertitle">
<div class="title">IpcServer.cpp</div>  </div>
</div><!--header-->
<div class="contents">
<a href="_ipc_server_8cpp.html">浏览该文件的文档.</a><div class="fragment"><div class="line"><a name="l00001"></a><span class="lineno">    1</span>&#160;<span class="preprocessor">#ifdef WIN32</span></div>
<div class="line"><a name="l00002"></a><span class="lineno">    2</span>&#160;<span class="preprocessor">#   include &quot;../../socket/internal/IocpService.h&quot;</span></div>
<div class="line"><a name="l00003"></a><span class="lineno">    3</span>&#160;<span class="preprocessor">#elif defined(LINUX)</span></div>
<div class="line"><a name="l00004"></a><span class="lineno">    4</span>&#160;<span class="preprocessor">#   include &quot;../../socket/internal/EpollService.h&quot;</span></div>
<div class="line"><a name="l00005"></a><span class="lineno">    5</span>&#160;<span class="preprocessor">#   include &quot;../../socket/SockTools.h&quot;</span></div>
<div class="line"><a name="l00006"></a><span class="lineno">    6</span>&#160;<span class="preprocessor">#endif</span></div>
<div class="line"><a name="l00007"></a><span class="lineno">    7</span>&#160;<span class="preprocessor">#include &quot;<a class="code" href="_ipc_server_8h.html">IpcServer.h</a>&quot;</span></div>
<div class="line"><a name="l00008"></a><span class="lineno">    8</span>&#160;<span class="preprocessor">#include &quot;<a class="code" href="_ipc_socket_8h.html">IpcSocket.h</a>&quot;</span></div>
<div class="line"><a name="l00009"></a><span class="lineno">    9</span>&#160;<span class="preprocessor">#include &quot;../../socket/internal/SockData.h&quot;</span></div>
<div class="line"><a name="l00010"></a><span class="lineno">   10</span>&#160;<span class="preprocessor">#include &quot;../../socket/SockException.h&quot;</span></div>
<div class="line"><a name="l00011"></a><span class="lineno">   11</span>&#160;<span class="preprocessor">#include &quot;../../socket/Timer.h&quot;</span></div>
<div class="line"><a name="l00012"></a><span class="lineno">   12</span>&#160;<span class="preprocessor">#include &lt;assert.h&gt;</span></div>
<div class="line"><a name="l00013"></a><span class="lineno">   13</span>&#160; </div>
<div class="line"><a name="l00014"></a><span class="lineno">   14</span>&#160;<a class="code" href="tools_8h.html#a201ce692c9dca6599e5c12d00167419b">DEF_BEG_LIBTOOLS</a></div>
<div class="line"><a name="l00015"></a><span class="lineno">   15</span>&#160; </div>
<div class="line"><a name="l00016"></a><span class="lineno"><a class="line" href="class_c_ipc_server.html#a887afeb1b4f43370624778e353cd6334">   16</a></span>&#160;<a class="code" href="class_c_ipc_server.html#a887afeb1b4f43370624778e353cd6334">CIpcServer::CIpcServer</a>(<span class="keywordtype">bool</span> isWriteLog):<a class="code" href="class_c_ipc_base.html">CIpcBase</a>(isWriteLog)</div>
<div class="line"><a name="l00017"></a><span class="lineno">   17</span>&#160;{</div>
<div class="line"><a name="l00018"></a><span class="lineno">   18</span>&#160;<span class="preprocessor">#ifdef WIN32</span></div>
<div class="line"><a name="l00019"></a><span class="lineno">   19</span>&#160;    <a class="code" href="class_c_ipc_server.html#a051d98b123da288b62b889650b25cfd2">_service</a>.<a class="code" href="class_shared_ptr.html#a0b0a4c8396bf40f91994f729855c0a5a">Reset</a>(<span class="keyword">new</span> CIocpService(&amp;<a class="code" href="class_c_ipc_server.html#a959278d613a745ec63d60bdf1480bbc8">CIpcServer::IoCompleteFunc</a>));</div>
<div class="line"><a name="l00020"></a><span class="lineno">   20</span>&#160;<span class="preprocessor">#elif defined(LINUX)</span></div>
<div class="line"><a name="l00021"></a><span class="lineno">   21</span>&#160;    <a class="code" href="class_c_ipc_server.html#a051d98b123da288b62b889650b25cfd2">_service</a>.<a class="code" href="class_shared_ptr.html#a0b0a4c8396bf40f91994f729855c0a5a">Reset</a>(<span class="keyword">new</span> <a class="code" href="class_c_epoll_service.html">CEpollService</a>(&amp;<a class="code" href="class_c_ipc_server.html#a959278d613a745ec63d60bdf1480bbc8">CIpcServer::IoCompleteFunc</a>));</div>
<div class="line"><a name="l00022"></a><span class="lineno">   22</span>&#160;<span class="preprocessor">#endif</span></div>
<div class="line"><a name="l00023"></a><span class="lineno">   23</span>&#160;    <a class="code" href="class_c_ipc_server.html#a051d98b123da288b62b889650b25cfd2">_service</a>-&gt;<a class="code" href="class_c_io_port_service.html#aedf29d5a0b744177d997d156068545bf">SetWriteLog</a>(isWriteLog);</div>
<div class="line"><a name="l00024"></a><span class="lineno">   24</span>&#160;}</div>
<div class="line"><a name="l00025"></a><span class="lineno">   25</span>&#160; </div>
<div class="line"><a name="l00026"></a><span class="lineno"><a class="line" href="class_c_ipc_server.html#a8ea46a0c695def5670ba92c0cd5ceea3">   26</a></span>&#160;<a class="code" href="class_c_ipc_server.html#a8ea46a0c695def5670ba92c0cd5ceea3">CIpcServer::~CIpcServer</a>()</div>
<div class="line"><a name="l00027"></a><span class="lineno">   27</span>&#160;{</div>
<div class="line"><a name="l00028"></a><span class="lineno">   28</span>&#160;<span class="preprocessor">#ifdef LINUX</span></div>
<div class="line"><a name="l00029"></a><span class="lineno">   29</span>&#160;    <span class="keywordflow">if</span>(<a class="code" href="class_c_ipc_server.html#a3516424d217f772b7db789a00a0e0eff">_svrSock</a>.<a class="code" href="class_shared_ptr.html#a0f15d2d3d2834b0667791f3abfd9e0d7">Get</a>() != <a class="code" href="tools_8h.html#ab689500aaec0db066e3ac9483d3fe425">NullPtr</a>) unlink(<a class="code" href="class_c_ipc_server.html#a3516424d217f772b7db789a00a0e0eff">_svrSock</a>-&gt;<a class="code" href="class_c_socket.html#adc23006ccfd784a08cbfd2a9c0d3c85e">GetAddr</a>().c_str());</div>
<div class="line"><a name="l00030"></a><span class="lineno">   30</span>&#160;<span class="preprocessor">#endif</span></div>
<div class="line"><a name="l00031"></a><span class="lineno">   31</span>&#160;}</div>
<div class="line"><a name="l00032"></a><span class="lineno">   32</span>&#160; </div>
<div class="line"><a name="l00033"></a><span class="lineno"><a class="line" href="class_c_ipc_server.html#a98dd72100abc97f8c8ae5f4641e18587">   33</a></span>&#160;<a class="code" href="class_c_sock_error.html">CSockError</a> <a class="code" href="class_c_ipc_server.html#a98dd72100abc97f8c8ae5f4641e18587">CIpcServer::Init</a>(<span class="keyword">const</span> <span class="keywordtype">char</span>* name)</div>
<div class="line"><a name="l00034"></a><span class="lineno">   34</span>&#160;{</div>
<div class="line"><a name="l00035"></a><span class="lineno">   35</span>&#160;    <a class="code" href="class_c_sock_error.html">CSockError</a> ec;</div>
<div class="line"><a name="l00036"></a><span class="lineno">   36</span>&#160;    <a class="code" href="class_c_ipc_server.html#a3516424d217f772b7db789a00a0e0eff">_svrSock</a> = <span class="keyword">new</span> <a class="code" href="class_c_ipc_socket.html">CIpcSocket</a>(<span class="keyword">this</span>);</div>
<div class="line"><a name="l00037"></a><span class="lineno">   37</span>&#160;    <a class="code" href="class_c_ipc_server.html#a3516424d217f772b7db789a00a0e0eff">_svrSock</a>-&gt;<a class="code" href="class_c_ipc_socket.html#ad954cee189b57a0bb1ff5c95c25de871">SetAddr</a>(name);</div>
<div class="line"><a name="l00038"></a><span class="lineno">   38</span>&#160;<span class="preprocessor">#ifdef WIN32</span></div>
<div class="line"><a name="l00039"></a><span class="lineno">   39</span>&#160;    <a class="code" href="class_c_ipc_server.html#a3516424d217f772b7db789a00a0e0eff">_svrSock</a>-&gt;<a class="code" href="class_c_socket.html#a630790930bc708f198f90181420892a5">SetProtocol</a>(<a class="code" href="namespace_s_o_c_k_p_r_o_t_o_c_o_l.html#a6fcb9a12773185f3ca183ad967bb672ea43d9e1a8ae64989aa870537a77c1fa8e">SOCKPROTOCOL::IPC_CREATE</a>);</div>
<div class="line"><a name="l00040"></a><span class="lineno">   40</span>&#160;    <a class="code" href="class_c_ipc_server.html#a3516424d217f772b7db789a00a0e0eff">_svrSock</a>-&gt;<a class="code" href="class_c_socket.html#aafc3fc3ab0c1e3d5ae2cf9dfba46d442">SetDomain</a>(<a class="code" href="namespace_s_o_c_k_f_a_m_i_l_y.html#a2752d06098f227dbd8340b30a718da81a7c983a10bd5c8139d1aa1268993d8604">SOCKFAMILY::IPC</a>);</div>
<div class="line"><a name="l00041"></a><span class="lineno">   41</span>&#160;    <a class="code" href="class_c_ipc_server.html#a3516424d217f772b7db789a00a0e0eff">_svrSock</a>-&gt;<a class="code" href="class_c_socket.html#ab0833e2e82bcca3a85057fcecb2287bb">SetSockType</a>(<a class="code" href="namespace_s_o_c_k_t_y_p_e.html#ab1b532206487defe92ed4eeae94b488ca001599c1c291d81e5145c9aaed42852d">SOCKTYPE::STREAM</a>);</div>
<div class="line"><a name="l00042"></a><span class="lineno">   42</span>&#160;    <a class="code" href="class_c_ipc_server.html#a3516424d217f772b7db789a00a0e0eff">_svrSock</a>-&gt;<a class="code" href="class_c_socket.html#a73320b641e5e5b001bee08048c9b6503">GetServiceBuffer</a>()-&gt;<a class="code" href="struct_sock_data_buffer.html#a00d6c264d2731009f0432398f7eea14e">isBindService</a> = <a class="code" href="tools_8h.html#aa8cecfc5c5c054d2875c03e77b7be15d">TRUE</a>;</div>
<div class="line"><a name="l00043"></a><span class="lineno">   43</span>&#160;<span class="preprocessor">#elif defined(LINUX)</span></div>
<div class="line"><a name="l00044"></a><span class="lineno">   44</span>&#160;    ec = dynamic_cast&lt;CSocket*&gt;(<a class="code" href="class_c_ipc_server.html#a3516424d217f772b7db789a00a0e0eff">_svrSock</a>.<a class="code" href="class_shared_ptr.html#a0f15d2d3d2834b0667791f3abfd9e0d7">Get</a>())-&gt;Socket(<a class="code" href="namespace_s_o_c_k_f_a_m_i_l_y.html#a2752d06098f227dbd8340b30a718da81a7c983a10bd5c8139d1aa1268993d8604">SOCKFAMILY::IPC</a>, <a class="code" href="namespace_s_o_c_k_t_y_p_e.html#ab1b532206487defe92ed4eeae94b488ca001599c1c291d81e5145c9aaed42852d">SOCKTYPE::STREAM</a>, <a class="code" href="namespace_s_o_c_k_p_r_o_t_o_c_o_l.html#a6fcb9a12773185f3ca183ad967bb672ea43d9e1a8ae64989aa870537a77c1fa8e">SOCKPROTOCOL::IPC_CREATE</a>);</div>
<div class="line"><a name="l00045"></a><span class="lineno">   45</span>&#160;    <span class="keywordflow">if</span> (!ec)</div>
<div class="line"><a name="l00046"></a><span class="lineno">   46</span>&#160;    {</div>
<div class="line"><a name="l00047"></a><span class="lineno">   47</span>&#160;        ec = <a class="code" href="_sock_tools_8cpp.html#ac5273d06745110e78bca129577ab2d06">Bind</a>(*<a class="code" href="class_c_ipc_server.html#a3516424d217f772b7db789a00a0e0eff">_svrSock</a>);</div>
<div class="line"><a name="l00048"></a><span class="lineno">   48</span>&#160;        <span class="keywordflow">if</span> (!ec)</div>
<div class="line"><a name="l00049"></a><span class="lineno">   49</span>&#160;        {</div>
<div class="line"><a name="l00050"></a><span class="lineno">   50</span>&#160;            ec = <a class="code" href="_sock_tools_8cpp.html#abface14c5278330909dd390d3d5a4332">Listen</a>(*<a class="code" href="class_c_ipc_server.html#a3516424d217f772b7db789a00a0e0eff">_svrSock</a>, 256);</div>
<div class="line"><a name="l00051"></a><span class="lineno">   51</span>&#160;            <span class="keywordflow">if</span>(!ec) ec = ec = <a class="code" href="class_c_ipc_server.html#a051d98b123da288b62b889650b25cfd2">_service</a>-&gt;<a class="code" href="class_c_io_port_service.html#afc1a07c4cf6e9aa6f2a00d157dfd9eed">Init</a>(*dynamic_cast&lt;CSocket*&gt;(<a class="code" href="class_c_ipc_server.html#a3516424d217f772b7db789a00a0e0eff">_svrSock</a>.<a class="code" href="class_shared_ptr.html#a0f15d2d3d2834b0667791f3abfd9e0d7">Get</a>()), <span class="keyword">true</span>);</div>
<div class="line"><a name="l00052"></a><span class="lineno">   52</span>&#160;        }</div>
<div class="line"><a name="l00053"></a><span class="lineno">   53</span>&#160;    }</div>
<div class="line"><a name="l00054"></a><span class="lineno">   54</span>&#160;<span class="preprocessor">#endif</span></div>
<div class="line"><a name="l00055"></a><span class="lineno">   55</span>&#160; </div>
<div class="line"><a name="l00056"></a><span class="lineno">   56</span>&#160;    <span class="keywordflow">return</span> ec;</div>
<div class="line"><a name="l00057"></a><span class="lineno">   57</span>&#160;}</div>
<div class="line"><a name="l00058"></a><span class="lineno">   58</span>&#160; </div>
<div class="line"><a name="l00059"></a><span class="lineno"><a class="line" href="class_c_ipc_server.html#a6efd34ab8eecc267c0ab2b0317091efd">   59</a></span>&#160;<span class="keywordtype">void</span> <a class="code" href="class_c_ipc_server.html#a6efd34ab8eecc267c0ab2b0317091efd">CIpcServer::AsyncAccept</a>(<a class="code" href="class_c_ipc_socket.html">CIpcSocket</a>&amp; cliSock, <span class="keyword">const</span> <a class="code" href="class_shared_ptr.html">SharedPtr&lt;HandleBase&gt;</a>&amp; func, <span class="keywordtype">void</span>* invoker <span class="comment">/* = NullPtr */</span>)</div>
<div class="line"><a name="l00060"></a><span class="lineno">   60</span>&#160;{</div>
<div class="line"><a name="l00061"></a><span class="lineno">   61</span>&#160;    <span class="keywordflow">if</span> (!<a class="code" href="class_c_ipc_server.html#a051d98b123da288b62b889650b25cfd2">_service</a>-&gt;<a class="code" href="class_c_io_port_service.html#a4e27edba8096659e67f2f275eeeba984">IsInit</a>()){</div>
<div class="line"><a name="l00062"></a><span class="lineno">   62</span>&#160;        <span class="keywordflow">throw</span> <a class="code" href="class_c_sock_exception.html">CSockException</a>(<a class="code" href="class_c_sock_error.html">CSockError</a>(<a class="code" href="namespace_s_o_c_k_e_t_s_t_a_t_u_s.html#a960fa087f22eb32da3c7d0c805be7876a5a76b20cc3c857f53d6e5e7e817c8959">CSockError::UNINIT</a>).GetErrorMsg().c_str());</div>
<div class="line"><a name="l00063"></a><span class="lineno">   63</span>&#160;    }</div>
<div class="line"><a name="l00064"></a><span class="lineno">   64</span>&#160;    cliSock.<a class="code" href="class_c_ipc_socket.html#ad954cee189b57a0bb1ff5c95c25de871">SetAddr</a>(<a class="code" href="class_c_ipc_server.html#a3516424d217f772b7db789a00a0e0eff">_svrSock</a>-&gt;<a class="code" href="class_c_socket.html#adc23006ccfd784a08cbfd2a9c0d3c85e">GetAddr</a>().c_str());</div>
<div class="line"><a name="l00065"></a><span class="lineno">   65</span>&#160;    cliSock.<a class="code" href="class_c_socket.html#aafc3fc3ab0c1e3d5ae2cf9dfba46d442">SetDomain</a>(<a class="code" href="class_c_ipc_server.html#a3516424d217f772b7db789a00a0e0eff">_svrSock</a>-&gt;<a class="code" href="class_c_socket.html#a8f9deafc91bedf6c25122fe98e8174d8">GetDomain</a>());</div>
<div class="line"><a name="l00066"></a><span class="lineno">   66</span>&#160;    cliSock.<a class="code" href="class_c_socket.html#a630790930bc708f198f90181420892a5">SetProtocol</a>(<a class="code" href="class_c_ipc_server.html#a3516424d217f772b7db789a00a0e0eff">_svrSock</a>-&gt;<a class="code" href="class_c_socket.html#a3258d90d4a7626508fc8c43e0893b020">GetProtocol</a>());</div>
<div class="line"><a name="l00067"></a><span class="lineno">   67</span>&#160;    cliSock.<a class="code" href="class_c_socket.html#ab0833e2e82bcca3a85057fcecb2287bb">SetSockType</a>(<a class="code" href="class_c_ipc_server.html#a3516424d217f772b7db789a00a0e0eff">_svrSock</a>-&gt;<a class="code" href="class_c_socket.html#a4db9f0924d9173baa17ffef5bfeeaa48">GetSockType</a>());</div>
<div class="line"><a name="l00068"></a><span class="lineno">   68</span>&#160;    <a class="code" href="class_c_ipc_server.html#a051d98b123da288b62b889650b25cfd2">_service</a>-&gt;<a class="code" href="class_c_io_port_service.html#aa9c6a13fde3ceae6b494568242681714">PostAcceptEx</a>(*dynamic_cast&lt;CSocket*&gt;(<a class="code" href="class_c_ipc_server.html#a3516424d217f772b7db789a00a0e0eff">_svrSock</a>.<a class="code" href="class_shared_ptr.html#a0f15d2d3d2834b0667791f3abfd9e0d7">Get</a>()), cliSock, func, invoker);</div>
<div class="line"><a name="l00069"></a><span class="lineno">   69</span>&#160;}</div>
<div class="line"><a name="l00070"></a><span class="lineno">   70</span>&#160; </div>
<div class="line"><a name="l00071"></a><span class="lineno"><a class="line" href="class_c_ipc_server.html#ab3190c4366dd9367b2c77d180ec1bf6c">   71</a></span>&#160;<span class="keywordtype">void</span> <a class="code" href="class_c_ipc_server.html#ab3190c4366dd9367b2c77d180ec1bf6c">CIpcServer::AsyncRead</a>(<a class="code" href="class_c_ipc_socket.html">CIpcSocket</a>&amp; sock, <span class="keyword">const</span> <a class="code" href="class_c_stream_iteator.html">CStreamIteator</a>&amp; buff, <span class="keyword">const</span> <a class="code" href="class_shared_ptr.html">SharedPtr&lt;HandleBase&gt;</a>&amp; func, <span class="keywordtype">void</span>* invoker <span class="comment">/* = NullPtr */</span>)</div>
<div class="line"><a name="l00072"></a><span class="lineno">   72</span>&#160;{</div>
<div class="line"><a name="l00073"></a><span class="lineno">   73</span>&#160;    <span class="keywordflow">if</span> (!<a class="code" href="class_c_ipc_server.html#a051d98b123da288b62b889650b25cfd2">_service</a>-&gt;<a class="code" href="class_c_io_port_service.html#a4e27edba8096659e67f2f275eeeba984">IsInit</a>()){</div>
<div class="line"><a name="l00074"></a><span class="lineno">   74</span>&#160;        <span class="keywordflow">throw</span> <a class="code" href="class_c_sock_exception.html">CSockException</a>(<a class="code" href="class_c_sock_error.html">CSockError</a>(<a class="code" href="namespace_s_o_c_k_e_t_s_t_a_t_u_s.html#a960fa087f22eb32da3c7d0c805be7876a5a76b20cc3c857f53d6e5e7e817c8959">CSockError::UNINIT</a>).GetErrorMsg().c_str());</div>
<div class="line"><a name="l00075"></a><span class="lineno">   75</span>&#160;    }</div>
<div class="line"><a name="l00076"></a><span class="lineno">   76</span>&#160; </div>
<div class="line"><a name="l00077"></a><span class="lineno">   77</span>&#160;    <a class="code" href="class_c_ipc_server.html#a051d98b123da288b62b889650b25cfd2">_service</a>-&gt;<a class="code" href="class_c_io_port_service.html#a258367c891c1b3f4208c7b41e95b864d">DeliveryRecv</a>(*dynamic_cast&lt;CSocket*&gt;(&amp;sock), const_cast&lt;char*&gt;(buff.<a class="code" href="class_c_stream_iteator.html#a0099f615b4deffd3273c9c4d7cae4a91">cbegin</a>()), const_cast&lt;char*&gt;(buff.<a class="code" href="class_c_stream_iteator.html#abd398f0c306bb0d8090328abdf29580a">cend</a>()), <a class="code" href="tools_8h.html#ab689500aaec0db066e3ac9483d3fe425">NullPtr</a>, func, invoker);</div>
<div class="line"><a name="l00078"></a><span class="lineno">   78</span>&#160;}</div>
<div class="line"><a name="l00079"></a><span class="lineno">   79</span>&#160; </div>
<div class="line"><a name="l00080"></a><span class="lineno"><a class="line" href="class_c_ipc_server.html#ac995cd72b148708616041968363efb12">   80</a></span>&#160;<span class="keywordtype">void</span> <a class="code" href="class_c_ipc_server.html#ac995cd72b148708616041968363efb12">CIpcServer::AsyncSend</a>(<a class="code" href="class_c_ipc_socket.html">CIpcSocket</a>&amp; sock, <span class="keyword">const</span> <a class="code" href="class_c_stream_iteator.html">CStreamIteator</a>&amp; buff, <span class="keyword">const</span> <a class="code" href="class_shared_ptr.html">SharedPtr&lt;HandleBase&gt;</a>&amp; func, <span class="keywordtype">void</span>* invoker <span class="comment">/* = NullPtr */</span>)</div>
<div class="line"><a name="l00081"></a><span class="lineno">   81</span>&#160;{</div>
<div class="line"><a name="l00082"></a><span class="lineno">   82</span>&#160;    <span class="keywordflow">if</span> (!<a class="code" href="class_c_ipc_server.html#a051d98b123da288b62b889650b25cfd2">_service</a>-&gt;<a class="code" href="class_c_io_port_service.html#a4e27edba8096659e67f2f275eeeba984">IsInit</a>()){</div>
<div class="line"><a name="l00083"></a><span class="lineno">   83</span>&#160;        <span class="keywordflow">throw</span> <a class="code" href="class_c_sock_exception.html">CSockException</a>(<a class="code" href="class_c_sock_error.html">CSockError</a>(<a class="code" href="namespace_s_o_c_k_e_t_s_t_a_t_u_s.html#a960fa087f22eb32da3c7d0c805be7876a5a76b20cc3c857f53d6e5e7e817c8959">CSockError::UNINIT</a>).GetErrorMsg().c_str());</div>
<div class="line"><a name="l00084"></a><span class="lineno">   84</span>&#160;    }</div>
<div class="line"><a name="l00085"></a><span class="lineno">   85</span>&#160; </div>
<div class="line"><a name="l00086"></a><span class="lineno">   86</span>&#160;    <a class="code" href="class_c_ipc_server.html#a051d98b123da288b62b889650b25cfd2">_service</a>-&gt;<a class="code" href="class_c_io_port_service.html#a61ce383d1dc8faf0f821237e4cc438cf">DeliveryWrite</a>(*dynamic_cast&lt;CSocket*&gt;(&amp;sock), const_cast&lt;char*&gt;(buff.<a class="code" href="class_c_stream_iteator.html#a0099f615b4deffd3273c9c4d7cae4a91">cbegin</a>()), const_cast&lt;char*&gt;(buff.<a class="code" href="class_c_stream_iteator.html#abd398f0c306bb0d8090328abdf29580a">cend</a>()), <a class="code" href="tools_8h.html#ab689500aaec0db066e3ac9483d3fe425">NullPtr</a>, func, invoker);</div>
<div class="line"><a name="l00087"></a><span class="lineno">   87</span>&#160;}</div>
<div class="line"><a name="l00088"></a><span class="lineno">   88</span>&#160; </div>
<div class="line"><a name="l00089"></a><span class="lineno"><a class="line" href="class_c_ipc_server.html#a88248174bc0338fdc4c942e4e715a539">   89</a></span>&#160;<span class="keywordtype">void</span> <a class="code" href="class_c_ipc_server.html#a88248174bc0338fdc4c942e4e715a539">CIpcServer::Post</a>(<span class="keyword">const</span> <a class="code" href="class_shared_ptr.html">SharedPtr&lt;HandleBase&gt;</a>&amp; func, <span class="keywordtype">void</span>* invoker <span class="comment">/* = NullPtr */</span>)</div>
<div class="line"><a name="l00090"></a><span class="lineno">   90</span>&#160;{</div>
<div class="line"><a name="l00091"></a><span class="lineno">   91</span>&#160;    <span class="keywordflow">if</span> (!<a class="code" href="class_c_ipc_server.html#a051d98b123da288b62b889650b25cfd2">_service</a>-&gt;<a class="code" href="class_c_io_port_service.html#a4e27edba8096659e67f2f275eeeba984">IsInit</a>()){</div>
<div class="line"><a name="l00092"></a><span class="lineno">   92</span>&#160;        <span class="keywordflow">throw</span> <a class="code" href="class_c_sock_exception.html">CSockException</a>(<a class="code" href="class_c_sock_error.html">CSockError</a>(<a class="code" href="namespace_s_o_c_k_e_t_s_t_a_t_u_s.html#a960fa087f22eb32da3c7d0c805be7876a5a76b20cc3c857f53d6e5e7e817c8959">CSockError::UNINIT</a>).GetErrorMsg().c_str());</div>
<div class="line"><a name="l00093"></a><span class="lineno">   93</span>&#160;    }</div>
<div class="line"><a name="l00094"></a><span class="lineno">   94</span>&#160; </div>
<div class="line"><a name="l00095"></a><span class="lineno">   95</span>&#160;    <a class="code" href="class_c_ipc_server.html#a051d98b123da288b62b889650b25cfd2">_service</a>-&gt;<a class="code" href="class_c_io_port_service.html#a2b82286514aa89ecd2a7470047c4845e">Post</a>(func, invoker);</div>
<div class="line"><a name="l00096"></a><span class="lineno">   96</span>&#160;}</div>
<div class="line"><a name="l00097"></a><span class="lineno">   97</span>&#160; </div>
<div class="line"><a name="l00098"></a><span class="lineno"><a class="line" href="class_c_ipc_server.html#ae56ad501c3bf4a84f756b6bf98e8865e">   98</a></span>&#160;<span class="keywordtype">bool</span> <a class="code" href="class_c_ipc_server.html#ae56ad501c3bf4a84f756b6bf98e8865e">CIpcServer::Run_One</a>()</div>
<div class="line"><a name="l00099"></a><span class="lineno">   99</span>&#160;{</div>
<div class="line"><a name="l00100"></a><span class="lineno">  100</span>&#160;    <span class="keywordflow">return</span> <a class="code" href="class_c_ipc_server.html#a051d98b123da288b62b889650b25cfd2">_service</a>-&gt;<a class="code" href="class_c_io_port_service.html#a8eb92d255bda145631e1dc57e42d3dba">Run_One</a>();</div>
<div class="line"><a name="l00101"></a><span class="lineno">  101</span>&#160;}</div>
<div class="line"><a name="l00102"></a><span class="lineno">  102</span>&#160; </div>
<div class="line"><a name="l00103"></a><span class="lineno"><a class="line" href="class_c_ipc_server.html#a33f88801a6fb30b8bfd9f0fdc063b77f">  103</a></span>&#160;<span class="keywordtype">bool</span> <a class="code" href="class_c_ipc_server.html#a33f88801a6fb30b8bfd9f0fdc063b77f">CIpcServer::Run</a>()</div>
<div class="line"><a name="l00104"></a><span class="lineno">  104</span>&#160;{</div>
<div class="line"><a name="l00105"></a><span class="lineno">  105</span>&#160;    <span class="keywordflow">return</span> <a class="code" href="class_c_ipc_server.html#a051d98b123da288b62b889650b25cfd2">_service</a>-&gt;<a class="code" href="class_c_io_port_service.html#a56a9ae4bb89bd85e21ae5507e3c6b093">Run</a>();</div>
<div class="line"><a name="l00106"></a><span class="lineno">  106</span>&#160;}</div>
<div class="line"><a name="l00107"></a><span class="lineno">  107</span>&#160; </div>
<div class="line"><a name="l00108"></a><span class="lineno"><a class="line" href="class_c_ipc_server.html#ac62bb4a375227fe83a343e91c2851ee2">  108</a></span>&#160;<span class="keywordtype">void</span> <a class="code" href="class_c_ipc_server.html#ac62bb4a375227fe83a343e91c2851ee2">CIpcServer::NotifyStop</a>()</div>
<div class="line"><a name="l00109"></a><span class="lineno">  109</span>&#160;{</div>
<div class="line"><a name="l00110"></a><span class="lineno">  110</span>&#160;    <span class="keywordflow">return</span> <a class="code" href="class_c_ipc_server.html#a051d98b123da288b62b889650b25cfd2">_service</a>-&gt;<a class="code" href="class_c_io_port_service.html#a88ce9281be3952a469f8c3b6bf0f9d5b">NotifyStop</a>();</div>
<div class="line"><a name="l00111"></a><span class="lineno">  111</span>&#160;}</div>
<div class="line"><a name="l00112"></a><span class="lineno">  112</span>&#160; </div>
<div class="line"><a name="l00113"></a><span class="lineno"><a class="line" href="class_c_ipc_server.html#a0101ecf81b0384a2f6180441890d9140">  113</a></span>&#160;<span class="keywordtype">void</span> <a class="code" href="class_c_ipc_server.html#a0101ecf81b0384a2f6180441890d9140">CIpcServer::WaitServerStop</a>()</div>
<div class="line"><a name="l00114"></a><span class="lineno">  114</span>&#160;{</div>
<div class="line"><a name="l00115"></a><span class="lineno">  115</span>&#160;    <a class="code" href="class_c_ipc_server.html#a051d98b123da288b62b889650b25cfd2">_service</a>-&gt;<a class="code" href="class_c_io_port_service.html#a88ce9281be3952a469f8c3b6bf0f9d5b">NotifyStop</a>();</div>
<div class="line"><a name="l00116"></a><span class="lineno">  116</span>&#160;    <a class="code" href="class_c_ipc_server.html#a051d98b123da288b62b889650b25cfd2">_service</a>-&gt;<a class="code" href="class_c_io_port_service.html#ae247b9ad53c577481a6a17713e6a0685">Shutdown</a>();</div>
<div class="line"><a name="l00117"></a><span class="lineno">  117</span>&#160;}</div>
<div class="line"><a name="l00118"></a><span class="lineno">  118</span>&#160; </div>
<div class="line"><a name="l00119"></a><span class="lineno"><a class="line" href="class_c_ipc_server.html#a9629de28739f75f42c63550081b19520">  119</a></span>&#160;<span class="keywordtype">bool</span> <a class="code" href="class_c_ipc_server.html#a9629de28739f75f42c63550081b19520">CIpcServer::IsStop</a>()<span class="keyword"> const</span></div>
<div class="line"><a name="l00120"></a><span class="lineno">  120</span>&#160;<span class="keyword"></span>{</div>
<div class="line"><a name="l00121"></a><span class="lineno">  121</span>&#160;    <span class="keywordflow">return</span> <a class="code" href="class_c_ipc_server.html#a051d98b123da288b62b889650b25cfd2">_service</a>-&gt;<a class="code" href="class_c_io_port_service.html#a87b609526def283ffb20cc4b4c082473">IsStop</a>();</div>
<div class="line"><a name="l00122"></a><span class="lineno">  122</span>&#160;}</div>
<div class="line"><a name="l00123"></a><span class="lineno">  123</span>&#160; </div>
<div class="line"><a name="l00124"></a><span class="lineno"><a class="line" href="class_c_ipc_server.html#aec573dd038c82993f08ee14648d5f01e">  124</a></span>&#160;<a class="code" href="class_c_io_port_service.html">CIoPortService</a>* <a class="code" href="class_c_ipc_server.html#aec573dd038c82993f08ee14648d5f01e">CIpcServer::GetIoPortService</a>()</div>
<div class="line"><a name="l00125"></a><span class="lineno">  125</span>&#160;{</div>
<div class="line"><a name="l00126"></a><span class="lineno">  126</span>&#160;    <span class="keywordflow">return</span> dynamic_cast&lt;CIoPortService*&gt;(<a class="code" href="class_c_ipc_server.html#a051d98b123da288b62b889650b25cfd2">_service</a>.<a class="code" href="class_shared_ptr.html#a0f15d2d3d2834b0667791f3abfd9e0d7">Get</a>());</div>
<div class="line"><a name="l00127"></a><span class="lineno">  127</span>&#160;}</div>
<div class="line"><a name="l00128"></a><span class="lineno">  128</span>&#160; </div>
<div class="line"><a name="l00129"></a><span class="lineno"><a class="line" href="class_c_ipc_server.html#a2f68d998b1e4b755441ea2c6d1eab68b">  129</a></span>&#160;<span class="keywordtype">void</span> <a class="code" href="class_c_ipc_server.html#a2f68d998b1e4b755441ea2c6d1eab68b">CIpcServer::DelTimer</a>(<a class="code" href="class_c_timer_base.html">CTimerBase</a>&amp; timer)</div>
<div class="line"><a name="l00130"></a><span class="lineno">  130</span>&#160;{</div>
<div class="line"><a name="l00131"></a><span class="lineno">  131</span>&#160;    <a class="code" href="class_c_ipc_server.html#a051d98b123da288b62b889650b25cfd2">_service</a>-&gt;<a class="code" href="class_c_io_port_service.html#a6a56a2a5a014ee11d4696eac5096d198">DelTimer</a>(*timer.<a class="code" href="class_c_timer_base.html#a1ea13f83b73eb54062006d563a5c2f85">GetTimerInfo</a>());</div>
<div class="line"><a name="l00132"></a><span class="lineno">  132</span>&#160;}</div>
<div class="line"><a name="l00133"></a><span class="lineno">  133</span>&#160; </div>
<div class="line"><a name="l00134"></a><span class="lineno"><a class="line" href="class_c_ipc_server.html#a31bc1a0fb9e64d32cb57f27a088c8a5b">  134</a></span>&#160;<span class="keywordtype">void</span> <a class="code" href="class_c_ipc_server.html#a31bc1a0fb9e64d32cb57f27a088c8a5b">CIpcServer::SetTimer</a>(<a class="code" href="class_c_timer_base.html">CTimerBase</a>&amp; timer)</div>
<div class="line"><a name="l00135"></a><span class="lineno">  135</span>&#160;{</div>
<div class="line"><a name="l00136"></a><span class="lineno">  136</span>&#160;    <a class="code" href="class_c_ipc_server.html#a051d98b123da288b62b889650b25cfd2">_service</a>-&gt;<a class="code" href="class_c_io_port_service.html#a5ffa1d9379ae7595d2febd119f42a738">SetTimer</a>(*timer.<a class="code" href="class_c_timer_base.html#a1ea13f83b73eb54062006d563a5c2f85">GetTimerInfo</a>());</div>
<div class="line"><a name="l00137"></a><span class="lineno">  137</span>&#160;}</div>
<div class="line"><a name="l00138"></a><span class="lineno">  138</span>&#160; </div>
<div class="line"><a name="l00139"></a><span class="lineno"><a class="line" href="class_c_ipc_server.html#a31a7557064b9a15ecf29f208528cf63f">  139</a></span>&#160;<span class="keywordtype">bool</span> <a class="code" href="class_c_ipc_server.html#a31a7557064b9a15ecf29f208528cf63f">CIpcServer::UpdateTimer</a>(<a class="code" href="class_c_timer_base.html">CTimerBase</a>&amp; timer)</div>
<div class="line"><a name="l00140"></a><span class="lineno">  140</span>&#160;{</div>
<div class="line"><a name="l00141"></a><span class="lineno">  141</span>&#160;    <span class="keywordflow">return</span> <a class="code" href="class_c_ipc_server.html#a051d98b123da288b62b889650b25cfd2">_service</a>-&gt;<a class="code" href="class_c_io_port_service.html#ac30315805f5476c9e5ff36f3fa542485">UpdateTimer</a>(*timer.<a class="code" href="class_c_timer_base.html#a1ea13f83b73eb54062006d563a5c2f85">GetTimerInfo</a>());</div>
<div class="line"><a name="l00142"></a><span class="lineno">  142</span>&#160;}</div>
<div class="line"><a name="l00143"></a><span class="lineno">  143</span>&#160; </div>
<div class="line"><a name="l00144"></a><span class="lineno"><a class="line" href="class_c_ipc_server.html#a959278d613a745ec63d60bdf1480bbc8">  144</a></span>&#160;<a class="code" href="tools_8h.html#a798af1e30bc65f319c1a246cecf59e39">DWORD</a> <a class="code" href="class_c_ipc_server.html#a959278d613a745ec63d60bdf1480bbc8">CIpcServer::IoCompleteFunc</a>(<a class="code" href="struct_o_v_e_r_l_a_p_p_e_d___e_x.html">OVERLAPPED_EX</a>* o)</div>
<div class="line"><a name="l00145"></a><span class="lineno">  145</span>&#160;{</div>
<div class="line"><a name="l00146"></a><span class="lineno">  146</span>&#160;    <a class="code" href="tools_8h.html#a798af1e30bc65f319c1a246cecf59e39">DWORD</a> dwRet = 0;</div>
<div class="line"><a name="l00147"></a><span class="lineno">  147</span>&#160;    <a class="code" href="class_shared_ptr.html">SharedPtr&lt;HandleBase&gt;</a> handle;</div>
<div class="line"><a name="l00148"></a><span class="lineno">  148</span>&#160;    handle.<a class="code" href="class_shared_ptr.html#a4d01af086ba301328e14f279a7ab400a">Swap</a>(o-&gt;<a class="code" href="struct_o_v_e_r_l_a_p_p_e_d___e_x.html#a2696e48028b12aa65b271ec208c5483c">handle</a>);</div>
<div class="line"><a name="l00149"></a><span class="lineno">  149</span>&#160;    <span class="keywordflow">if</span> (o-&gt;<a class="code" href="struct_o_v_e_r_l_a_p_p_e_d___e_x.html#a614e5742d57e4905fdf46b8727486b5e">sockStatus</a> == <a class="code" href="namespace_s_o_c_k_e_t_s_t_a_t_u_s.html#a960fa087f22eb32da3c7d0c805be7876a0000a02186d14b5d44fdc32c6079d613">SOCKETSTATUS::ACCEPTED</a>)</div>
<div class="line"><a name="l00150"></a><span class="lineno">  150</span>&#160;    {</div>
<div class="line"><a name="l00151"></a><span class="lineno">  151</span>&#160;        dwRet = (*handle)(o-&gt;<a class="code" href="struct_o_v_e_r_l_a_p_p_e_d___e_x.html#a29eca265ddf9e8858e7360a27004866b">sockError</a>, o-&gt;<a class="code" href="struct_o_v_e_r_l_a_p_p_e_d___e_x.html#af6cda33264504094d59752d5725eb8e6">invoker</a>);</div>
<div class="line"><a name="l00152"></a><span class="lineno">  152</span>&#160;    }</div>
<div class="line"><a name="l00153"></a><span class="lineno">  153</span>&#160;    <span class="keywordflow">else</span> <span class="keywordflow">if</span> (o-&gt;<a class="code" href="struct_o_v_e_r_l_a_p_p_e_d___e_x.html#a614e5742d57e4905fdf46b8727486b5e">sockStatus</a> == <a class="code" href="namespace_s_o_c_k_e_t_s_t_a_t_u_s.html#a960fa087f22eb32da3c7d0c805be7876a8e36da283b8c83b61bab630b9b858724">SOCKETSTATUS::RECVED</a>)</div>
<div class="line"><a name="l00154"></a><span class="lineno">  154</span>&#160;    {</div>
<div class="line"><a name="l00155"></a><span class="lineno">  155</span>&#160;        dwRet = (*handle)(o-&gt;<a class="code" href="struct_o_v_e_r_l_a_p_p_e_d___e_x.html#a3da45429c23fe76e84378d5dcfd24daa">wsaPtr</a>.<a class="code" href="struct___w_s_a_b_u_f.html#a018f049fe75c6f822a1765f16fdcb1f6">buf</a>, o-&gt;<a class="code" href="struct_o_v_e_r_l_a_p_p_e_d___e_x.html#a46009f6f99e2e4e9e648f51ad55927ef">dwRead</a>, o-&gt;<a class="code" href="struct_o_v_e_r_l_a_p_p_e_d___e_x.html#a29eca265ddf9e8858e7360a27004866b">sockError</a>, o-&gt;<a class="code" href="struct_o_v_e_r_l_a_p_p_e_d___e_x.html#af6cda33264504094d59752d5725eb8e6">invoker</a>);</div>
<div class="line"><a name="l00156"></a><span class="lineno">  156</span>&#160;    }</div>
<div class="line"><a name="l00157"></a><span class="lineno">  157</span>&#160;    <span class="keywordflow">else</span> <span class="keywordflow">if</span> (o-&gt;<a class="code" href="struct_o_v_e_r_l_a_p_p_e_d___e_x.html#a614e5742d57e4905fdf46b8727486b5e">sockStatus</a> == <a class="code" href="namespace_s_o_c_k_e_t_s_t_a_t_u_s.html#a960fa087f22eb32da3c7d0c805be7876a52566ca153bf6bcb661b1e8e606d3b5b">SOCKETSTATUS::SENDED</a>)</div>
<div class="line"><a name="l00158"></a><span class="lineno">  158</span>&#160;    {</div>
<div class="line"><a name="l00159"></a><span class="lineno">  159</span>&#160;        dwRet = (*handle)(o-&gt;<a class="code" href="struct_o_v_e_r_l_a_p_p_e_d___e_x.html#a3da45429c23fe76e84378d5dcfd24daa">wsaPtr</a>.<a class="code" href="struct___w_s_a_b_u_f.html#a018f049fe75c6f822a1765f16fdcb1f6">buf</a>, o-&gt;<a class="code" href="struct_o_v_e_r_l_a_p_p_e_d___e_x.html#ae3a09cbbd58ac06dfd92673e3e7130fd">dwWrite</a>, o-&gt;<a class="code" href="struct_o_v_e_r_l_a_p_p_e_d___e_x.html#a29eca265ddf9e8858e7360a27004866b">sockError</a>, o-&gt;<a class="code" href="struct_o_v_e_r_l_a_p_p_e_d___e_x.html#af6cda33264504094d59752d5725eb8e6">invoker</a>);</div>
<div class="line"><a name="l00160"></a><span class="lineno">  160</span>&#160;    }</div>
<div class="line"><a name="l00161"></a><span class="lineno">  161</span>&#160;    <span class="keywordflow">else</span> <span class="keywordflow">if</span> (o-&gt;<a class="code" href="struct_o_v_e_r_l_a_p_p_e_d___e_x.html#a614e5742d57e4905fdf46b8727486b5e">sockStatus</a> == <a class="code" href="namespace_s_o_c_k_e_t_s_t_a_t_u_s.html#a960fa087f22eb32da3c7d0c805be7876acbc6a92d2f6de3cda399fb0de0ffdd98">SOCKETSTATUS::POST</a>)</div>
<div class="line"><a name="l00162"></a><span class="lineno">  162</span>&#160;    {</div>
<div class="line"><a name="l00163"></a><span class="lineno">  163</span>&#160;        dwRet = (*handle)(o-&gt;<a class="code" href="struct_o_v_e_r_l_a_p_p_e_d___e_x.html#af6cda33264504094d59752d5725eb8e6">invoker</a>);</div>
<div class="line"><a name="l00164"></a><span class="lineno">  164</span>&#160;    }</div>
<div class="line"><a name="l00165"></a><span class="lineno">  165</span>&#160;    <span class="keywordflow">else</span></div>
<div class="line"><a name="l00166"></a><span class="lineno">  166</span>&#160;    {</div>
<div class="line"><a name="l00167"></a><span class="lineno">  167</span>&#160;        assert(dwRet);</div>
<div class="line"><a name="l00168"></a><span class="lineno">  168</span>&#160;    }</div>
<div class="line"><a name="l00169"></a><span class="lineno">  169</span>&#160; </div>
<div class="line"><a name="l00170"></a><span class="lineno">  170</span>&#160;    <span class="keywordflow">return</span> dwRet;</div>
<div class="line"><a name="l00171"></a><span class="lineno">  171</span>&#160;}</div>
<div class="line"><a name="l00172"></a><span class="lineno">  172</span>&#160; </div>
<div class="line"><a name="l00173"></a><span class="lineno">  173</span>&#160;<a class="code" href="tools_8h.html#ac909db71799bb22cb7d636a34cd785e4">DEF_END_LIBTOOLS</a></div>
</div><!-- fragment --></div><!-- contents -->
<div class="ttc" id="aclass_c_ipc_server_html_a051d98b123da288b62b889650b25cfd2"><div class="ttname"><a href="class_c_ipc_server.html#a051d98b123da288b62b889650b25cfd2">CIpcServer::_service</a></div><div class="ttdeci">SharedPtr&lt; CIoPortService &gt; _service</div><div class="ttdef"><b>Definition:</b> <a href="_ipc_server_8h_source.html#l00083">IpcServer.h:83</a></div></div>
<div class="ttc" id="aclass_c_ipc_server_html_a6efd34ab8eecc267c0ab2b0317091efd"><div class="ttname"><a href="class_c_ipc_server.html#a6efd34ab8eecc267c0ab2b0317091efd">CIpcServer::AsyncAccept</a></div><div class="ttdeci">virtual void AsyncAccept(CIpcSocket &amp;cliSock, const SharedPtr&lt; HandleBase &gt; &amp;func, void *invoker=NullPtr)</div><div class="ttdoc">投递一个接收连接请求</div><div class="ttdef"><b>Definition:</b> <a href="_ipc_server_8cpp_source.html#l00059">IpcServer.cpp:59</a></div></div>
<div class="ttc" id="aclass_c_io_port_service_html_a56a9ae4bb89bd85e21ae5507e3c6b093"><div class="ttname"><a href="class_c_io_port_service.html#a56a9ae4bb89bd85e21ae5507e3c6b093">CIoPortService::Run</a></div><div class="ttdeci">virtual bool Run()=0</div><div class="ttdoc">运行服务</div></div>
<div class="ttc" id="aclass_c_ipc_server_html_ac995cd72b148708616041968363efb12"><div class="ttname"><a href="class_c_ipc_server.html#ac995cd72b148708616041968363efb12">CIpcServer::AsyncSend</a></div><div class="ttdeci">virtual void AsyncSend(CIpcSocket &amp;sock, const CStreamIteator &amp;buff, const SharedPtr&lt; HandleBase &gt; &amp;func, void *invoker=NullPtr)</div><div class="ttdoc">投递一个写请求</div><div class="ttdef"><b>Definition:</b> <a href="_ipc_server_8cpp_source.html#l00080">IpcServer.cpp:80</a></div></div>
<div class="ttc" id="aclass_c_io_port_service_html_a61ce383d1dc8faf0f821237e4cc438cf"><div class="ttname"><a href="class_c_io_port_service.html#a61ce383d1dc8faf0f821237e4cc438cf">CIoPortService::DeliveryWrite</a></div><div class="ttdeci">virtual void DeliveryWrite(CSocket &amp;sock, const char *first, const char *end, CSockAddr *addr, const SharedPtr&lt; HandleBase &gt; &amp;func, void *invoker=NullPtr)=0</div><div class="ttdoc">投递一个写请求</div></div>
<div class="ttc" id="aclass_c_sock_error_html"><div class="ttname"><a href="class_c_sock_error.html">CSockError</a></div><div class="ttdoc">套接字错误信息类</div><div class="ttdef"><b>Definition:</b> <a href="_sock_error_8h_source.html#l00013">SockError.h:13</a></div></div>
<div class="ttc" id="aclass_c_timer_base_html_a1ea13f83b73eb54062006d563a5c2f85"><div class="ttname"><a href="class_c_timer_base.html#a1ea13f83b73eb54062006d563a5c2f85">CTimerBase::GetTimerInfo</a></div><div class="ttdeci">TimeoutInfo * GetTimerInfo()</div><div class="ttdoc">获取底层时间信息</div><div class="ttdef"><b>Definition:</b> <a href="_timer_8cpp_source.html#l00091">Timer.cpp:91</a></div></div>
<div class="ttc" id="aclass_c_ipc_server_html_a31a7557064b9a15ecf29f208528cf63f"><div class="ttname"><a href="class_c_ipc_server.html#a31a7557064b9a15ecf29f208528cf63f">CIpcServer::UpdateTimer</a></div><div class="ttdeci">virtual bool UpdateTimer(CTimerBase &amp;timer)</div><div class="ttdef"><b>Definition:</b> <a href="_ipc_server_8cpp_source.html#l00139">IpcServer.cpp:139</a></div></div>
<div class="ttc" id="aclass_c_stream_iteator_html"><div class="ttname"><a href="class_c_stream_iteator.html">CStreamIteator</a></div><div class="ttdef"><b>Definition:</b> <a href="_stream_byte_8h_source.html#l00011">StreamByte.h:11</a></div></div>
<div class="ttc" id="anamespace_s_o_c_k_e_t_s_t_a_t_u_s_html_a960fa087f22eb32da3c7d0c805be7876a52566ca153bf6bcb661b1e8e606d3b5b"><div class="ttname"><a href="namespace_s_o_c_k_e_t_s_t_a_t_u_s.html#a960fa087f22eb32da3c7d0c805be7876a52566ca153bf6bcb661b1e8e606d3b5b">SOCKETSTATUS::SENDED</a></div><div class="ttdoc">发送完成</div><div class="ttdef"><b>Definition:</b> <a href="_socket_def_8h_source.html#l00094">SocketDef.h:94</a></div></div>
<div class="ttc" id="aclass_c_socket_html_aafc3fc3ab0c1e3d5ae2cf9dfba46d442"><div class="ttname"><a href="class_c_socket.html#aafc3fc3ab0c1e3d5ae2cf9dfba46d442">CSocket::SetDomain</a></div><div class="ttdeci">virtual void SetDomain(SOCKFAMILY::SockFamily domain=SOCKFAMILY::IPV4)</div><div class="ttdoc">设置协议族,注意重置该值将会清空地址、端口信息</div><div class="ttdef"><b>Definition:</b> <a href="_socket_8cpp_source.html#l00181">Socket.cpp:181</a></div></div>
<div class="ttc" id="astruct_o_v_e_r_l_a_p_p_e_d___e_x_html_a46009f6f99e2e4e9e648f51ad55927ef"><div class="ttname"><a href="struct_o_v_e_r_l_a_p_p_e_d___e_x.html#a46009f6f99e2e4e9e648f51ad55927ef">OVERLAPPED_EX::dwRead</a></div><div class="ttdeci">DWORD dwRead</div><div class="ttdoc">当前读取的字节数</div><div class="ttdef"><b>Definition:</b> <a href="_sock_data_8h_source.html#l00070">SockData.h:70</a></div></div>
<div class="ttc" id="aclass_c_ipc_server_html_a959278d613a745ec63d60bdf1480bbc8"><div class="ttname"><a href="class_c_ipc_server.html#a959278d613a745ec63d60bdf1480bbc8">CIpcServer::IoCompleteFunc</a></div><div class="ttdeci">static DWORD IoCompleteFunc(OVERLAPPED_EX *o)</div><div class="ttdef"><b>Definition:</b> <a href="_ipc_server_8cpp_source.html#l00144">IpcServer.cpp:144</a></div></div>
<div class="ttc" id="anamespace_s_o_c_k_p_r_o_t_o_c_o_l_html_a6fcb9a12773185f3ca183ad967bb672ea43d9e1a8ae64989aa870537a77c1fa8e"><div class="ttname"><a href="namespace_s_o_c_k_p_r_o_t_o_c_o_l.html#a6fcb9a12773185f3ca183ad967bb672ea43d9e1a8ae64989aa870537a77c1fa8e">SOCKPROTOCOL::IPC_CREATE</a></div><div class="ttdoc">创建IPC，当作为服务端连接时使用（仅CIpcSocket使用）</div><div class="ttdef"><b>Definition:</b> <a href="_socket_def_8h_source.html#l00034">SocketDef.h:34</a></div></div>
<div class="ttc" id="aclass_shared_ptr_html"><div class="ttname"><a href="class_shared_ptr.html">SharedPtr&lt; HandleBase &gt;</a></div></div>
<div class="ttc" id="atools_8h_html_aa8cecfc5c5c054d2875c03e77b7be15d"><div class="ttname"><a href="tools_8h.html#aa8cecfc5c5c054d2875c03e77b7be15d">TRUE</a></div><div class="ttdeci">#define TRUE</div><div class="ttdef"><b>Definition:</b> <a href="tools_8h_source.html#l00147">tools.h:147</a></div></div>
<div class="ttc" id="aclass_shared_ptr_html_a0f15d2d3d2834b0667791f3abfd9e0d7"><div class="ttname"><a href="class_shared_ptr.html#a0f15d2d3d2834b0667791f3abfd9e0d7">SharedPtr::Get</a></div><div class="ttdeci">Ty * Get()</div><div class="ttdef"><b>Definition:</b> <a href="_shared_ptr_8h_source.html#l00202">SharedPtr.h:202</a></div></div>
<div class="ttc" id="astruct_o_v_e_r_l_a_p_p_e_d___e_x_html_a2696e48028b12aa65b271ec208c5483c"><div class="ttname"><a href="struct_o_v_e_r_l_a_p_p_e_d___e_x.html#a2696e48028b12aa65b271ec208c5483c">OVERLAPPED_EX::handle</a></div><div class="ttdeci">SharedPtr&lt; HandleBase &gt; handle</div><div class="ttdoc">用户完成回调函数</div><div class="ttdef"><b>Definition:</b> <a href="_sock_data_8h_source.html#l00068">SockData.h:68</a></div></div>
<div class="ttc" id="aclass_c_ipc_server_html_a887afeb1b4f43370624778e353cd6334"><div class="ttname"><a href="class_c_ipc_server.html#a887afeb1b4f43370624778e353cd6334">CIpcServer::CIpcServer</a></div><div class="ttdeci">CIpcServer(bool isWriteLog)</div><div class="ttdef"><b>Definition:</b> <a href="_ipc_server_8cpp_source.html#l00016">IpcServer.cpp:16</a></div></div>
<div class="ttc" id="aclass_c_socket_html_a4db9f0924d9173baa17ffef5bfeeaa48"><div class="ttname"><a href="class_c_socket.html#a4db9f0924d9173baa17ffef5bfeeaa48">CSocket::GetSockType</a></div><div class="ttdeci">virtual SOCKTYPE::SockType GetSockType() const</div><div class="ttdoc">获取套接字发送类型</div><div class="ttdef"><b>Definition:</b> <a href="_socket_8cpp_source.html#l00203">Socket.cpp:203</a></div></div>
<div class="ttc" id="aclass_c_io_port_service_html_a8eb92d255bda145631e1dc57e42d3dba"><div class="ttname"><a href="class_c_io_port_service.html#a8eb92d255bda145631e1dc57e42d3dba">CIoPortService::Run_One</a></div><div class="ttdeci">virtual bool Run_One()=0</div><div class="ttdoc">运行一次服务</div></div>
<div class="ttc" id="atools_8h_html_a201ce692c9dca6599e5c12d00167419b"><div class="ttname"><a href="tools_8h.html#a201ce692c9dca6599e5c12d00167419b">DEF_BEG_LIBTOOLS</a></div><div class="ttdeci">#define DEF_BEG_LIBTOOLS</div><div class="ttdef"><b>Definition:</b> <a href="tools_8h_source.html#l00036">tools.h:36</a></div></div>
<div class="ttc" id="astruct_o_v_e_r_l_a_p_p_e_d___e_x_html_af6cda33264504094d59752d5725eb8e6"><div class="ttname"><a href="struct_o_v_e_r_l_a_p_p_e_d___e_x.html#af6cda33264504094d59752d5725eb8e6">OVERLAPPED_EX::invoker</a></div><div class="ttdeci">void * invoker</div><div class="ttdoc">用户数据</div><div class="ttdef"><b>Definition:</b> <a href="_sock_data_8h_source.html#l00076">SockData.h:76</a></div></div>
<div class="ttc" id="aclass_c_io_port_service_html_a6a56a2a5a014ee11d4696eac5096d198"><div class="ttname"><a href="class_c_io_port_service.html#a6a56a2a5a014ee11d4696eac5096d198">CIoPortService::DelTimer</a></div><div class="ttdeci">virtual void DelTimer(TimerInfo &amp;tinfo)=0</div><div class="ttdoc">删除定时器</div></div>
<div class="ttc" id="aclass_c_ipc_server_html_a8ea46a0c695def5670ba92c0cd5ceea3"><div class="ttname"><a href="class_c_ipc_server.html#a8ea46a0c695def5670ba92c0cd5ceea3">CIpcServer::~CIpcServer</a></div><div class="ttdeci">virtual ~CIpcServer()</div><div class="ttdef"><b>Definition:</b> <a href="_ipc_server_8cpp_source.html#l00026">IpcServer.cpp:26</a></div></div>
<div class="ttc" id="aclass_c_io_port_service_html_a258367c891c1b3f4208c7b41e95b864d"><div class="ttname"><a href="class_c_io_port_service.html#a258367c891c1b3f4208c7b41e95b864d">CIoPortService::DeliveryRecv</a></div><div class="ttdeci">virtual void DeliveryRecv(CSocket &amp;sock, char *first, char *end, CSockAddr *addr, const SharedPtr&lt; HandleBase &gt; &amp;func, void *invoker=NullPtr)=0</div><div class="ttdoc">投递一个接收请求</div></div>
<div class="ttc" id="aclass_c_ipc_server_html_ac62bb4a375227fe83a343e91c2851ee2"><div class="ttname"><a href="class_c_ipc_server.html#ac62bb4a375227fe83a343e91c2851ee2">CIpcServer::NotifyStop</a></div><div class="ttdeci">virtual void NotifyStop()</div><div class="ttdoc">通知服务停止</div><div class="ttdef"><b>Definition:</b> <a href="_ipc_server_8cpp_source.html#l00108">IpcServer.cpp:108</a></div></div>
<div class="ttc" id="aclass_c_io_port_service_html_ac30315805f5476c9e5ff36f3fa542485"><div class="ttname"><a href="class_c_io_port_service.html#ac30315805f5476c9e5ff36f3fa542485">CIoPortService::UpdateTimer</a></div><div class="ttdeci">virtual bool UpdateTimer(TimerInfo &amp;tinfo)=0</div><div class="ttdoc">更新定时器</div></div>
<div class="ttc" id="anamespace_s_o_c_k_e_t_s_t_a_t_u_s_html_a960fa087f22eb32da3c7d0c805be7876a8e36da283b8c83b61bab630b9b858724"><div class="ttname"><a href="namespace_s_o_c_k_e_t_s_t_a_t_u_s.html#a960fa087f22eb32da3c7d0c805be7876a8e36da283b8c83b61bab630b9b858724">SOCKETSTATUS::RECVED</a></div><div class="ttdoc">接收完成</div><div class="ttdef"><b>Definition:</b> <a href="_socket_def_8h_source.html#l00098">SocketDef.h:98</a></div></div>
<div class="ttc" id="aclass_shared_ptr_html_a4d01af086ba301328e14f279a7ab400a"><div class="ttname"><a href="class_shared_ptr.html#a4d01af086ba301328e14f279a7ab400a">SharedPtr::Swap</a></div><div class="ttdeci">void Swap(SharedPtr&lt; Ty &gt; &amp;ptr)</div><div class="ttdef"><b>Definition:</b> <a href="_shared_ptr_8h_source.html#l00245">SharedPtr.h:245</a></div></div>
<div class="ttc" id="astruct_sock_data_buffer_html_a00d6c264d2731009f0432398f7eea14e"><div class="ttname"><a href="struct_sock_data_buffer.html#a00d6c264d2731009f0432398f7eea14e">SockDataBuffer::isBindService</a></div><div class="ttdeci">BOOL isBindService</div><div class="ttdoc">是否已绑定服务</div><div class="ttdef"><b>Definition:</b> <a href="_sock_data_8h_source.html#l00116">SockData.h:116</a></div></div>
<div class="ttc" id="aclass_c_ipc_server_html_a88248174bc0338fdc4c942e4e715a539"><div class="ttname"><a href="class_c_ipc_server.html#a88248174bc0338fdc4c942e4e715a539">CIpcServer::Post</a></div><div class="ttdeci">virtual void Post(const SharedPtr&lt; HandleBase &gt; &amp;func, void *invoker=NullPtr)</div><div class="ttdoc">投递一个中断请求</div><div class="ttdef"><b>Definition:</b> <a href="_ipc_server_8cpp_source.html#l00089">IpcServer.cpp:89</a></div></div>
<div class="ttc" id="aclass_c_epoll_service_html"><div class="ttname"><a href="class_c_epoll_service.html">CEpollService</a></div><div class="ttdef"><b>Definition:</b> <a href="_epoll_service_8h_source.html#l00023">EpollService.h:23</a></div></div>
<div class="ttc" id="aclass_c_ipc_socket_html_ad954cee189b57a0bb1ff5c95c25de871"><div class="ttname"><a href="class_c_ipc_socket.html#ad954cee189b57a0bb1ff5c95c25de871">CIpcSocket::SetAddr</a></div><div class="ttdeci">virtual void SetAddr(const char *name)</div><div class="ttdoc">设置管道名称、或者unix套接字名称</div><div class="ttdef"><b>Definition:</b> <a href="_ipc_socket_8cpp_source.html#l00048">IpcSocket.cpp:48</a></div></div>
<div class="ttc" id="astruct_o_v_e_r_l_a_p_p_e_d___e_x_html_ae3a09cbbd58ac06dfd92673e3e7130fd"><div class="ttname"><a href="struct_o_v_e_r_l_a_p_p_e_d___e_x.html#ae3a09cbbd58ac06dfd92673e3e7130fd">OVERLAPPED_EX::dwWrite</a></div><div class="ttdeci">DWORD dwWrite</div><div class="ttdoc">当前写入的字节数</div><div class="ttdef"><b>Definition:</b> <a href="_sock_data_8h_source.html#l00071">SockData.h:71</a></div></div>
<div class="ttc" id="astruct_o_v_e_r_l_a_p_p_e_d___e_x_html_a3da45429c23fe76e84378d5dcfd24daa"><div class="ttname"><a href="struct_o_v_e_r_l_a_p_p_e_d___e_x.html#a3da45429c23fe76e84378d5dcfd24daa">OVERLAPPED_EX::wsaPtr</a></div><div class="ttdeci">WSABUF wsaPtr</div><div class="ttdoc">发送或接受缓存区</div><div class="ttdef"><b>Definition:</b> <a href="_sock_data_8h_source.html#l00072">SockData.h:72</a></div></div>
<div class="ttc" id="aclass_c_ipc_server_html_ab3190c4366dd9367b2c77d180ec1bf6c"><div class="ttname"><a href="class_c_ipc_server.html#ab3190c4366dd9367b2c77d180ec1bf6c">CIpcServer::AsyncRead</a></div><div class="ttdeci">virtual void AsyncRead(CIpcSocket &amp;sock, const CStreamIteator &amp;buff, const SharedPtr&lt; HandleBase &gt; &amp;func, void *invoker=NullPtr)</div><div class="ttdoc">投递一个接收请求</div><div class="ttdef"><b>Definition:</b> <a href="_ipc_server_8cpp_source.html#l00071">IpcServer.cpp:71</a></div></div>
<div class="ttc" id="aclass_c_timer_base_html"><div class="ttname"><a href="class_c_timer_base.html">CTimerBase</a></div><div class="ttdoc">定时器</div><div class="ttdef"><b>Definition:</b> <a href="_timer_8h_source.html#l00017">Timer.h:17</a></div></div>
<div class="ttc" id="anamespace_s_o_c_k_f_a_m_i_l_y_html_a2752d06098f227dbd8340b30a718da81a7c983a10bd5c8139d1aa1268993d8604"><div class="ttname"><a href="namespace_s_o_c_k_f_a_m_i_l_y.html#a2752d06098f227dbd8340b30a718da81a7c983a10bd5c8139d1aa1268993d8604">SOCKFAMILY::IPC</a></div><div class="ttdoc">进程间的通信,仅CIpcSocket使用</div><div class="ttdef"><b>Definition:</b> <a href="_socket_def_8h_source.html#l00060">SocketDef.h:60</a></div></div>
<div class="ttc" id="aclass_c_ipc_server_html_a31bc1a0fb9e64d32cb57f27a088c8a5b"><div class="ttname"><a href="class_c_ipc_server.html#a31bc1a0fb9e64d32cb57f27a088c8a5b">CIpcServer::SetTimer</a></div><div class="ttdeci">virtual void SetTimer(CTimerBase &amp;timer)</div><div class="ttdef"><b>Definition:</b> <a href="_ipc_server_8cpp_source.html#l00134">IpcServer.cpp:134</a></div></div>
<div class="ttc" id="aclass_c_ipc_server_html_ae56ad501c3bf4a84f756b6bf98e8865e"><div class="ttname"><a href="class_c_ipc_server.html#ae56ad501c3bf4a84f756b6bf98e8865e">CIpcServer::Run_One</a></div><div class="ttdeci">virtual bool Run_One()</div><div class="ttdoc">运行服务一次</div><div class="ttdef"><b>Definition:</b> <a href="_ipc_server_8cpp_source.html#l00098">IpcServer.cpp:98</a></div></div>
<div class="ttc" id="atools_8h_html_ac909db71799bb22cb7d636a34cd785e4"><div class="ttname"><a href="tools_8h.html#ac909db71799bb22cb7d636a34cd785e4">DEF_END_LIBTOOLS</a></div><div class="ttdeci">#define DEF_END_LIBTOOLS</div><div class="ttdef"><b>Definition:</b> <a href="tools_8h_source.html#l00038">tools.h:38</a></div></div>
<div class="ttc" id="aclass_c_ipc_base_html"><div class="ttname"><a href="class_c_ipc_base.html">CIpcBase</a></div><div class="ttdoc">进程间通信基类</div><div class="ttdef"><b>Definition:</b> <a href="_ipc_base_8h_source.html#l00014">IpcBase.h:14</a></div></div>
<div class="ttc" id="aclass_c_io_port_service_html_aa9c6a13fde3ceae6b494568242681714"><div class="ttname"><a href="class_c_io_port_service.html#aa9c6a13fde3ceae6b494568242681714">CIoPortService::PostAcceptEx</a></div><div class="ttdeci">virtual void PostAcceptEx(CSocket &amp;svrSock, CSocket &amp;cliSock, const SharedPtr&lt; HandleBase &gt; &amp;func, void *invoker=NullPtr)=0</div><div class="ttdoc">投递一个接收连接请求</div></div>
<div class="ttc" id="aclass_c_stream_iteator_html_abd398f0c306bb0d8090328abdf29580a"><div class="ttname"><a href="class_c_stream_iteator.html#abd398f0c306bb0d8090328abdf29580a">CStreamIteator::cend</a></div><div class="ttdeci">virtual const char * cend() const</div><div class="ttdoc">返回序列结束位置</div><div class="ttdef"><b>Definition:</b> <a href="_stream_byte_8cpp_source.html#l00026">StreamByte.cpp:26</a></div></div>
<div class="ttc" id="astruct_o_v_e_r_l_a_p_p_e_d___e_x_html"><div class="ttname"><a href="struct_o_v_e_r_l_a_p_p_e_d___e_x.html">OVERLAPPED_EX</a></div><div class="ttdef"><b>Definition:</b> <a href="_sock_data_8h_source.html#l00063">SockData.h:63</a></div></div>
<div class="ttc" id="a_ipc_server_8h_html"><div class="ttname"><a href="_ipc_server_8h.html">IpcServer.h</a></div></div>
<div class="ttc" id="aclass_c_ipc_server_html_a3516424d217f772b7db789a00a0e0eff"><div class="ttname"><a href="class_c_ipc_server.html#a3516424d217f772b7db789a00a0e0eff">CIpcServer::_svrSock</a></div><div class="ttdeci">SharedPtr&lt; CIpcSocket &gt; _svrSock</div><div class="ttdef"><b>Definition:</b> <a href="_ipc_server_8h_source.html#l00084">IpcServer.h:84</a></div></div>
<div class="ttc" id="aclass_c_io_port_service_html_aedf29d5a0b744177d997d156068545bf"><div class="ttname"><a href="class_c_io_port_service.html#aedf29d5a0b744177d997d156068545bf">CIoPortService::SetWriteLog</a></div><div class="ttdeci">void SetWriteLog(bool bWriteLog)</div><div class="ttdoc">设置日志输出函数</div><div class="ttdef"><b>Definition:</b> <a href="_io_port_service_8h_source.html#l00114">IoPortService.h:114</a></div></div>
<div class="ttc" id="aclass_c_sock_exception_html"><div class="ttname"><a href="class_c_sock_exception.html">CSockException</a></div><div class="ttdoc">sockeet操作异常类</div><div class="ttdef"><b>Definition:</b> <a href="_sock_exception_8h_source.html#l00012">SockException.h:12</a></div></div>
<div class="ttc" id="aclass_shared_ptr_html_a0b0a4c8396bf40f91994f729855c0a5a"><div class="ttname"><a href="class_shared_ptr.html#a0b0a4c8396bf40f91994f729855c0a5a">SharedPtr::Reset</a></div><div class="ttdeci">void Reset(Ty *p)</div><div class="ttdef"><b>Definition:</b> <a href="_shared_ptr_8h_source.html#l00175">SharedPtr.h:175</a></div></div>
<div class="ttc" id="aclass_c_ipc_server_html_a9629de28739f75f42c63550081b19520"><div class="ttname"><a href="class_c_ipc_server.html#a9629de28739f75f42c63550081b19520">CIpcServer::IsStop</a></div><div class="ttdeci">virtual bool IsStop() const</div><div class="ttdoc">判断服务是否停止</div><div class="ttdef"><b>Definition:</b> <a href="_ipc_server_8cpp_source.html#l00119">IpcServer.cpp:119</a></div></div>
<div class="ttc" id="a_sock_tools_8cpp_html_ac5273d06745110e78bca129577ab2d06"><div class="ttname"><a href="_sock_tools_8cpp.html#ac5273d06745110e78bca129577ab2d06">Bind</a></div><div class="ttdeci">CSockError Bind(CSocket &amp;sock, const char *szAddr, DWORD port)</div><div class="ttdoc">绑定套接字端口</div><div class="ttdef"><b>Definition:</b> <a href="_sock_tools_8cpp_source.html#l00033">SockTools.cpp:33</a></div></div>
<div class="ttc" id="a_ipc_socket_8h_html"><div class="ttname"><a href="_ipc_socket_8h.html">IpcSocket.h</a></div></div>
<div class="ttc" id="aclass_c_io_port_service_html_a5ffa1d9379ae7595d2febd119f42a738"><div class="ttname"><a href="class_c_io_port_service.html#a5ffa1d9379ae7595d2febd119f42a738">CIoPortService::SetTimer</a></div><div class="ttdeci">virtual void SetTimer(TimerInfo &amp;tinfo)=0</div><div class="ttdoc">设置定时器</div></div>
<div class="ttc" id="anamespace_s_o_c_k_e_t_s_t_a_t_u_s_html_a960fa087f22eb32da3c7d0c805be7876acbc6a92d2f6de3cda399fb0de0ffdd98"><div class="ttname"><a href="namespace_s_o_c_k_e_t_s_t_a_t_u_s.html#a960fa087f22eb32da3c7d0c805be7876acbc6a92d2f6de3cda399fb0de0ffdd98">SOCKETSTATUS::POST</a></div><div class="ttdoc">用户请求</div><div class="ttdef"><b>Definition:</b> <a href="_socket_def_8h_source.html#l00105">SocketDef.h:105</a></div></div>
<div class="ttc" id="aclass_c_stream_iteator_html_a0099f615b4deffd3273c9c4d7cae4a91"><div class="ttname"><a href="class_c_stream_iteator.html#a0099f615b4deffd3273c9c4d7cae4a91">CStreamIteator::cbegin</a></div><div class="ttdeci">virtual const char * cbegin() const</div><div class="ttdoc">返回序列开始位置</div><div class="ttdef"><b>Definition:</b> <a href="_stream_byte_8cpp_source.html#l00021">StreamByte.cpp:21</a></div></div>
<div class="ttc" id="atools_8h_html_a798af1e30bc65f319c1a246cecf59e39"><div class="ttname"><a href="tools_8h.html#a798af1e30bc65f319c1a246cecf59e39">DWORD</a></div><div class="ttdeci">unsigned int DWORD</div><div class="ttdef"><b>Definition:</b> <a href="tools_8h_source.html#l00134">tools.h:134</a></div></div>
<div class="ttc" id="aclass_c_io_port_service_html"><div class="ttname"><a href="class_c_io_port_service.html">CIoPortService</a></div><div class="ttdef"><b>Definition:</b> <a href="_io_port_service_8h_source.html#l00032">IoPortService.h:32</a></div></div>
<div class="ttc" id="aclass_c_socket_html_a8f9deafc91bedf6c25122fe98e8174d8"><div class="ttname"><a href="class_c_socket.html#a8f9deafc91bedf6c25122fe98e8174d8">CSocket::GetDomain</a></div><div class="ttdeci">virtual SOCKFAMILY::SockFamily GetDomain() const</div><div class="ttdoc">获取协议族</div><div class="ttdef"><b>Definition:</b> <a href="_socket_8cpp_source.html#l00198">Socket.cpp:198</a></div></div>
<div class="ttc" id="aclass_c_io_port_service_html_a87b609526def283ffb20cc4b4c082473"><div class="ttname"><a href="class_c_io_port_service.html#a87b609526def283ffb20cc4b4c082473">CIoPortService::IsStop</a></div><div class="ttdeci">virtual bool IsStop() const =0</div><div class="ttdoc">服务是否停止</div></div>
<div class="ttc" id="aclass_c_socket_html_a630790930bc708f198f90181420892a5"><div class="ttname"><a href="class_c_socket.html#a630790930bc708f198f90181420892a5">CSocket::SetProtocol</a></div><div class="ttdeci">virtual void SetProtocol(SOCKPROTOCOL::SockProtocol protocol=SOCKPROTOCOL::TCP)</div><div class="ttdoc">设置协议类型</div><div class="ttdef"><b>Definition:</b> <a href="_socket_8cpp_source.html#l00188">Socket.cpp:188</a></div></div>
<div class="ttc" id="aclass_c_ipc_server_html_a2f68d998b1e4b755441ea2c6d1eab68b"><div class="ttname"><a href="class_c_ipc_server.html#a2f68d998b1e4b755441ea2c6d1eab68b">CIpcServer::DelTimer</a></div><div class="ttdeci">virtual void DelTimer(CTimerBase &amp;timer)</div><div class="ttdef"><b>Definition:</b> <a href="_ipc_server_8cpp_source.html#l00129">IpcServer.cpp:129</a></div></div>
<div class="ttc" id="atools_8h_html_ab689500aaec0db066e3ac9483d3fe425"><div class="ttname"><a href="tools_8h.html#ab689500aaec0db066e3ac9483d3fe425">NullPtr</a></div><div class="ttdeci">#define NullPtr</div><div class="ttdef"><b>Definition:</b> <a href="tools_8h_source.html#l00119">tools.h:119</a></div></div>
<div class="ttc" id="aclass_c_io_port_service_html_a4e27edba8096659e67f2f275eeeba984"><div class="ttname"><a href="class_c_io_port_service.html#a4e27edba8096659e67f2f275eeeba984">CIoPortService::IsInit</a></div><div class="ttdeci">virtual bool IsInit() const =0</div></div>
<div class="ttc" id="aclass_c_socket_html_ab0833e2e82bcca3a85057fcecb2287bb"><div class="ttname"><a href="class_c_socket.html#ab0833e2e82bcca3a85057fcecb2287bb">CSocket::SetSockType</a></div><div class="ttdeci">virtual void SetSockType(SOCKTYPE::SockType type=SOCKTYPE::STREAM)</div><div class="ttdoc">设置套接字发送类型</div><div class="ttdef"><b>Definition:</b> <a href="_socket_8cpp_source.html#l00193">Socket.cpp:193</a></div></div>
<div class="ttc" id="aclass_c_socket_html_adc23006ccfd784a08cbfd2a9c0d3c85e"><div class="ttname"><a href="class_c_socket.html#adc23006ccfd784a08cbfd2a9c0d3c85e">CSocket::GetAddr</a></div><div class="ttdeci">virtual std::string GetAddr() const</div><div class="ttdoc">获取连接或绑定的地址</div><div class="ttdef"><b>Definition:</b> <a href="_socket_8cpp_source.html#l00213">Socket.cpp:213</a></div></div>
<div class="ttc" id="astruct_o_v_e_r_l_a_p_p_e_d___e_x_html_a614e5742d57e4905fdf46b8727486b5e"><div class="ttname"><a href="struct_o_v_e_r_l_a_p_p_e_d___e_x.html#a614e5742d57e4905fdf46b8727486b5e">OVERLAPPED_EX::sockStatus</a></div><div class="ttdeci">DWORD sockStatus</div><div class="ttdoc">套接口的状态</div><div class="ttdef"><b>Definition:</b> <a href="_sock_data_8h_source.html#l00074">SockData.h:74</a></div></div>
<div class="ttc" id="aclass_c_io_port_service_html_afc1a07c4cf6e9aa6f2a00d157dfd9eed"><div class="ttname"><a href="class_c_io_port_service.html#afc1a07c4cf6e9aa6f2a00d157dfd9eed">CIoPortService::Init</a></div><div class="ttdeci">virtual CSockError Init(CSocket &amp;sock, bool isServer=false)=0</div></div>
<div class="ttc" id="aclass_c_io_port_service_html_a88ce9281be3952a469f8c3b6bf0f9d5b"><div class="ttname"><a href="class_c_io_port_service.html#a88ce9281be3952a469f8c3b6bf0f9d5b">CIoPortService::NotifyStop</a></div><div class="ttdeci">virtual void NotifyStop()=0</div><div class="ttdoc">通知停止服务</div></div>
<div class="ttc" id="aclass_c_ipc_server_html_a98dd72100abc97f8c8ae5f4641e18587"><div class="ttname"><a href="class_c_ipc_server.html#a98dd72100abc97f8c8ae5f4641e18587">CIpcServer::Init</a></div><div class="ttdeci">virtual CSockError Init(const char *name)</div><div class="ttdoc">初始化服务器</div><div class="ttdef"><b>Definition:</b> <a href="_ipc_server_8cpp_source.html#l00033">IpcServer.cpp:33</a></div></div>
<div class="ttc" id="a_sock_tools_8cpp_html_abface14c5278330909dd390d3d5a4332"><div class="ttname"><a href="_sock_tools_8cpp.html#abface14c5278330909dd390d3d5a4332">Listen</a></div><div class="ttdeci">CSockError Listen(CSocket &amp;sock, int backlog)</div><div class="ttdoc">监听套接字</div><div class="ttdef"><b>Definition:</b> <a href="_sock_tools_8cpp_source.html#l00067">SockTools.cpp:67</a></div></div>
<div class="ttc" id="aclass_c_socket_html_a3258d90d4a7626508fc8c43e0893b020"><div class="ttname"><a href="class_c_socket.html#a3258d90d4a7626508fc8c43e0893b020">CSocket::GetProtocol</a></div><div class="ttdeci">virtual SOCKPROTOCOL::SockProtocol GetProtocol() const</div><div class="ttdoc">获取协议类型</div><div class="ttdef"><b>Definition:</b> <a href="_socket_8cpp_source.html#l00208">Socket.cpp:208</a></div></div>
<div class="ttc" id="astruct_o_v_e_r_l_a_p_p_e_d___e_x_html_a29eca265ddf9e8858e7360a27004866b"><div class="ttname"><a href="struct_o_v_e_r_l_a_p_p_e_d___e_x.html#a29eca265ddf9e8858e7360a27004866b">OVERLAPPED_EX::sockError</a></div><div class="ttdeci">CSockError sockError</div><div class="ttdoc">错误码</div><div class="ttdef"><b>Definition:</b> <a href="_sock_data_8h_source.html#l00075">SockData.h:75</a></div></div>
<div class="ttc" id="anamespace_s_o_c_k_e_t_s_t_a_t_u_s_html_a960fa087f22eb32da3c7d0c805be7876a0000a02186d14b5d44fdc32c6079d613"><div class="ttname"><a href="namespace_s_o_c_k_e_t_s_t_a_t_u_s.html#a960fa087f22eb32da3c7d0c805be7876a0000a02186d14b5d44fdc32c6079d613">SOCKETSTATUS::ACCEPTED</a></div><div class="ttdoc">接收完成</div><div class="ttdef"><b>Definition:</b> <a href="_socket_def_8h_source.html#l00091">SocketDef.h:91</a></div></div>
<div class="ttc" id="aclass_c_io_port_service_html_a2b82286514aa89ecd2a7470047c4845e"><div class="ttname"><a href="class_c_io_port_service.html#a2b82286514aa89ecd2a7470047c4845e">CIoPortService::Post</a></div><div class="ttdeci">virtual void Post(const SharedPtr&lt; HandleBase &gt; &amp;func, void *invoker=NullPtr)=0</div><div class="ttdoc">投递一个中断请求</div></div>
<div class="ttc" id="aclass_c_ipc_server_html_a0101ecf81b0384a2f6180441890d9140"><div class="ttname"><a href="class_c_ipc_server.html#a0101ecf81b0384a2f6180441890d9140">CIpcServer::WaitServerStop</a></div><div class="ttdeci">virtual void WaitServerStop()</div><div class="ttdoc">通知服务停止并等待</div><div class="ttdef"><b>Definition:</b> <a href="_ipc_server_8cpp_source.html#l00113">IpcServer.cpp:113</a></div></div>
<div class="ttc" id="astruct___w_s_a_b_u_f_html_a018f049fe75c6f822a1765f16fdcb1f6"><div class="ttname"><a href="struct___w_s_a_b_u_f.html#a018f049fe75c6f822a1765f16fdcb1f6">_WSABUF::buf</a></div><div class="ttdeci">CHAR * buf</div><div class="ttdef"><b>Definition:</b> <a href="_sock_data_8h_source.html#l00022">SockData.h:22</a></div></div>
<div class="ttc" id="aclass_c_ipc_server_html_a33f88801a6fb30b8bfd9f0fdc063b77f"><div class="ttname"><a href="class_c_ipc_server.html#a33f88801a6fb30b8bfd9f0fdc063b77f">CIpcServer::Run</a></div><div class="ttdeci">virtual bool Run()</div><div class="ttdoc">运行服务</div><div class="ttdef"><b>Definition:</b> <a href="_ipc_server_8cpp_source.html#l00103">IpcServer.cpp:103</a></div></div>
<div class="ttc" id="aclass_c_io_port_service_html_ae247b9ad53c577481a6a17713e6a0685"><div class="ttname"><a href="class_c_io_port_service.html#ae247b9ad53c577481a6a17713e6a0685">CIoPortService::Shutdown</a></div><div class="ttdeci">virtual int Shutdown()=0</div><div class="ttdoc">停止服务,该函数会等待所有的线程退出</div></div>
<div class="ttc" id="aclass_c_ipc_socket_html"><div class="ttname"><a href="class_c_ipc_socket.html">CIpcSocket</a></div><div class="ttdoc">ipc通信专用套接字</div><div class="ttdef"><b>Definition:</b> <a href="_ipc_socket_8h_source.html#l00010">IpcSocket.h:10</a></div></div>
<div class="ttc" id="aclass_c_socket_html_a73320b641e5e5b001bee08048c9b6503"><div class="ttname"><a href="class_c_socket.html#a73320b641e5e5b001bee08048c9b6503">CSocket::GetServiceBuffer</a></div><div class="ttdeci">virtual SockDataBuffer * GetServiceBuffer() const</div><div class="ttdef"><b>Definition:</b> <a href="_socket_8cpp_source.html#l00276">Socket.cpp:276</a></div></div>
<div class="ttc" id="anamespace_s_o_c_k_e_t_s_t_a_t_u_s_html_a960fa087f22eb32da3c7d0c805be7876a5a76b20cc3c857f53d6e5e7e817c8959"><div class="ttname"><a href="namespace_s_o_c_k_e_t_s_t_a_t_u_s.html#a960fa087f22eb32da3c7d0c805be7876a5a76b20cc3c857f53d6e5e7e817c8959">SOCKETSTATUS::UNINIT</a></div><div class="ttdoc">未初始化</div><div class="ttdef"><b>Definition:</b> <a href="_socket_def_8h_source.html#l00087">SocketDef.h:87</a></div></div>
<div class="ttc" id="aclass_c_ipc_server_html_aec573dd038c82993f08ee14648d5f01e"><div class="ttname"><a href="class_c_ipc_server.html#aec573dd038c82993f08ee14648d5f01e">CIpcServer::GetIoPortService</a></div><div class="ttdeci">virtual CIoPortService * GetIoPortService()</div><div class="ttdoc">返回底层服务指针</div><div class="ttdef"><b>Definition:</b> <a href="_ipc_server_8cpp_source.html#l00124">IpcServer.cpp:124</a></div></div>
<div class="ttc" id="anamespace_s_o_c_k_t_y_p_e_html_ab1b532206487defe92ed4eeae94b488ca001599c1c291d81e5145c9aaed42852d"><div class="ttname"><a href="namespace_s_o_c_k_t_y_p_e.html#ab1b532206487defe92ed4eeae94b488ca001599c1c291d81e5145c9aaed42852d">SOCKTYPE::STREAM</a></div><div class="ttdoc">socket数据流</div><div class="ttdef"><b>Definition:</b> <a href="_socket_def_8h_source.html#l00047">SocketDef.h:47</a></div></div>
<!-- start footer part -->
<hr class="footer"/><address class="footer"><small>
制作者 &#160;<a href="http://www.doxygen.org/index.html">
<img class="footer" src="doxygen.png" alt="doxygen"/>
</a> 1.8.16
</small></address>
</body>
</html>
